package it.gma.torero.operand;

import it.gma.torero.util.Assert;

public class VariableBinderOperand extends AbstractComparationOperand {

	private VariableBinder context;

	public VariableBinderOperand(String variableName) {
		super(variableName);
		Assert.notNull(variableName);
	}

	public boolean isConstant() {
		return false;
	}

	@Override
	public Object getValue() {
		return context.bind((String) value);
	}

	public void setContext(VariableBinder context) {
		this.context = context;
	}

}
